import http from "@/utils/request";

export default {
    //查询油井和水井情况列表
    async getYjqkList(pageNo, pageSize, startDate, endDate) {
        return await http.get("/api/Jyjclyxhz/listYj", { pageNo, pageSize, startDate, endDate });
    },
    //查询油井和水井情况列表
    async getSjqkList(pageNo, pageSize, startDate, endDate) {
      return await http.get("/api/Jyjclyxhz/listSj", { pageNo, pageSize, startDate, endDate });
    },
    //查询水井情况列表
    async geYjByZtList(pageNo, pageSize, sgzt,startDate, endDate) {
        return await http.get("/api/Jyjclyxhz/listZtYj", { pageNo, pageSize, sgzt, startDate, endDate });
    },
    //按照井型查询数据
    async getYjByJxList(pageNo, pageSize, jlx, startDate, endDate) {
        return await http.get("/api/Jyjclyxhz/listLxYj", { pageNo, pageSize, jlx, startDate, endDate });
    },
    //查询水井详情列表
    async geSjByZtList(pageNo, pageSize, sgzt, startDate, endDate) {
        return await http.get("/api/Jyjclyxhz/listZtSj", { pageNo, pageSize, sgzt, startDate, endDate });
    },
    //查询油井和水井情况列表
    async getYjqkListByZyq(pageNo, pageSize,zyqmc, startDate, endDate) {
      return await http.get("/api/Jyjclyxhz/listYjByZyq", { pageNo, pageSize,zyqmc, startDate, endDate });
    },
    //查询水井情况列表
    async geYjByZtListByZyq(pageNo, pageSize, sgzt,zyqmc,startDate, endDate) {
      return await http.get("/api/Jyjclyxhz/listZtYjByZyq", { pageNo, pageSize, sgzt, zyqmc,startDate, endDate });
    },
    //按照井型查询数据
    async getYjByJxListByZyq(pageNo, pageSize, jlx,zyqmc, startDate, endDate) {
      return await http.get("/api/Jyjclyxhz/listLxYjByZyq", { pageNo, pageSize, jlx,zyqmc, startDate, endDate });
    },
    //查询油井和水井情况列表
    async getSjqkListByZyq(pageNo, pageSize,zyqmc, startDate, endDate) {
      return await http.get("/api/Jyjclyxhz/listSjByZyq", { pageNo, pageSize,zyqmc, startDate, endDate });
    },
    //查询水井情况列表
    async geSjByZtListByZyq(pageNo, pageSize, sgzt,zyqmc,startDate, endDate) {
      return await http.get("/api/Jyjclyxhz/listZtSjByZyq", { pageNo, pageSize, sgzt, zyqmc,startDate, endDate });
    },


    // /**查询总览信息**/
    // async addYjqk(params) {
    //     return await http.post("/api/jyjclyxhzb/add", params);
    // },

    /**查询容器区信息**/
    async addYjqk(params) {
        return await http.post("/api/yjqk/add", params);
    },


    /**查询加热炉区信息**/
    async addSjqk(params) {
        return await http.post("/api/sjqk/add", params);
    },

    /**查询机泵区信息**/
    async addYjxq(params) {
        return await http.post("/api/yjzy/add", params);
    },
    async addSjxq(params) {
        return await http.post("/api/sjzy/add", params);
    },


    //编辑产量情况
    async updateYjqk(params) {
        return await http.put("/api/yjqk/update", params);
    },
    //编辑产量情况
    async updateSjqk(params) {
        return await http.put("/api/sjqk/update", params);
    },
    //编辑产量情况
    async updateYjxq(params) {
        return await http.put("/api/yjzy/update", params);
    },
    //编辑产量情况
    async updateSjxq(params) {
        return await http.put("/api/sjzy/update", params);
    },
    // //删除产量情况
    // async deleteClqk(params) {
    //     return await http.delete("/api/clqk/delete", params);
    // },
    async importExcel(myfile) {
        console.log(29999999);
        console.log(myfile.get("myfile"));

        return await http.upload("/api/fileAbout/fileUpload", { myfile })
    },

    //导入文件
    async batchImportExcel(filePath) {
        console.log(typeof (filePath));
        console.log(filePath.get("filePath"));
        return await http.upload("/api/jyjclyxhzb/batchInput", { filePath })
    },
    //下载模板
    async download(params) {
        // console.log(1);
        return await http.get("/api/jyjclyxhzb/downLoadExcel", params)
    },
    //删除
    async delete(params) {
        return await http.delete('api/jyjclyxhzb/delete', params);

    },
    //批量删除
    async Bdelete(params) {
        return await http.post('/api/jyjclyxhzb/batchDelete', params);

    }
};
